package com.duobaoyu.dby.supply.db.repository.refund.impl;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.duobaoyu.dby.common.mybatis.base.DbyServiceImpl;
import com.duobaoyu.dby.supply.common.biz.dto.refund.AfterSaleApplyQueryDTO;
import com.duobaoyu.dby.supply.common.biz.vo.refund.AfterSaleExportVO;
import com.duobaoyu.dby.supply.common.biz.vo.refund.AfterSaleListVO;
import com.duobaoyu.dby.supply.db.entity.refund.AfterSale;
import com.duobaoyu.dby.supply.db.mapper.refund.AfterSaleMapper;
import com.duobaoyu.dby.supply.db.repository.refund.AfterSaleRepository;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Repository;

/**
 * @author yw
 * @description
 * @date 2023/9/27 15:37
 */
@Repository
@RequiredArgsConstructor
public class AfterSaleRepositoryImpl extends DbyServiceImpl<AfterSaleMapper, AfterSale> implements AfterSaleRepository {

    private final AfterSaleMapper afterSaleMapper;
    @Override
    public long afterSaleExportCount(AfterSaleApplyQueryDTO afterSaleApplyQuery) {

        return afterSaleMapper.afterSaleExportCount(afterSaleApplyQuery);
    }

    @Override
    public Page<AfterSaleExportVO> queryExportPage(Page<Object> page, AfterSaleApplyQueryDTO afterSaleApplyQuery) {

        return afterSaleMapper.queryExportPage(page,afterSaleApplyQuery);
    }

    @Override
    public boolean exists(Wrapper<AfterSale> queryWrapper) {

        return afterSaleMapper.exists(queryWrapper);
    }

    @Override
    public Page<AfterSaleListVO> queryPage(IPage<AfterSaleListVO> page, AfterSaleApplyQueryDTO afterSaleApplyQuery) {
        return afterSaleMapper.queryPage(page,afterSaleApplyQuery);
    }
}
